﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace iemtm.WeChat.Application.SystemCenter
{
    public interface IAnnouceAppService
    {
        /// <summary>
        /// 获取工单列表（分页）
        /// </summary>
        /// <param name="times">全部0 一周7 半月15 本月30</param>
        /// <param name="pagesize">每页多少数据，默认50</param>
        /// <param name="topNum">配合sql语句</param>
        /// <param name="menuIndex">页面tab选项 0：待接单 1：执行中 2：已结单 3：已审核</param>
        /// <param name="paraStr">查询条件</param>
        /// <returns></returns>
        Task<dynamic> GetAnnListByPage(int times = 0, int pagesize = 50, int topNum = 1, int menuIndex = 0, string paraStr = "");
        /// <summary>
        /// 工单列表统计数量
        /// </summary>
        /// <param name="times"></param>
        /// <param name="paraStr"></param>
        /// <returns></returns>      
        Task<dynamic> GetAnnCount(int times = 0, string paraStr = "");

        /// <summary>
        /// 查询油机和采集器信息-签到扫描事件
        /// </summary>
        /// <param name="type"></param>
        /// <param name="paraStr"></param>
        /// <returns></returns>     
        dynamic GetGenSetOrDtuidInfo(string type, string paraStr);

        /// <summary>
        /// 用户处理通知单(接单,签到,扫码油机)
        /// </summary>
        /// <param name="annouceCode"></param>
        /// <param name="AnnounceStatus"></param>
        /// <param name="longitude"></param>
        /// <param name="latitude"></param>
        /// <param name="gensetNum"></param>
        /// <param name="registeredDtuId"></param>
        Task<dynamic> UserProcessAnnouce(string annouceCode, string AnnounceStatus, double longitude, double latitude, string gensetNum, string generationFor, string registeredDtuId);
        /// <summary>
        /// 正常回单操作(效果与App保持一致)
        /// </summary>
        /// <param name="annouceCode"></param>
        /// <param name="userCode"></param>
        /// <param name="FinishRemak"></param>
        /// <returns></returns>
        Task<dynamic> replyGensetMethod(string annouceCode, string userCode, string FinishRemak);



        /// <summary>
        /// 更换油机接口
        /// </summary>
        /// <param name="annouceCode"></param>
        /// <param name="AnnounceId"></param>
        /// <param name="gensetNum"></param>
        /// <param name="registeredDtuId"></param>
        /// <param name="ChangeReason"></param>
        /// <returns></returns>
        Task<dynamic> ChangeAnnGensetMethod(string annouceCode, string AnnounceId, string gensetNum, string registeredDtuId, string ChangeReason);

        /// <summary>
        /// 正常回单时检查是否绑定发电记录
        /// </summary>
        /// <param name="annouceCode"></param>
        /// <returns></returns>
        Task<dynamic> IsBindGenRecord(string annouceCode);

        /// <summary>
        /// 续签接口
        /// </summary>
        /// <param name="annouceCode"></param>
        /// <param name="AnnounceId"></param>
        /// <param name="gensetNum"></param>
        /// <param name="registeredDtuId"></param>
        /// <returns></returns>
        Task<dynamic> ReBinAnnGensetMethod(string annouceCode, string AnnounceId, string gensetNum, string registeredDtuId);
    }
}
